



 |
Troubleshooting and Configuring the Windows NT/95 Registry
-16-
Questions and Answers
for Hardware and the Registry
Sometimes the information you need isn't really an error or a problem, but you
want to be able to do something that isn't normally allowed, or maybe something that
Microsoft didn't even dream of. Exceptional performance comes from being able to
add 2 plus 2 and get 8, or even 10. The standard answer will always be four, but
if you can take options in the Registry and make them give you extra, unplanned capabilities,
you will always succeed in getting optimum usability from your systems. It is the
"art" of computing, added on top of the science.
SOLUTIONS: I
have a communications program that is supposed to be compatible with NT and 95, but
it doesn't allow the use of COM3 or COM4. I don't have COM1 or COM2 available. Can
I make the software use COM3 or COM4? Windows NT does not allow the use of COM3 or
COM4 for modems, so its software isn't written for it. If you change the Registry,
it will work. The key to change is HKEY_LOCAL_MACHINE\HARDWARE\ DEVICEMAP\serialcomm.
Add a string value called COM3 if you want to add COM3, or COM4
if you need to use COM4. The text string is the same as the value name (com3=com3).
Restart the system, and you will be able to use the software with COM3 or COM4.
Hardware settings are one of the most critical functions in working with the Registry.
The Registry can also control the software that works with the hardware, as the next
question illustrates.Solutions
SOLUTIONS: When ScanDisk runs through
the System Agent inside Windows 95, it always pauses for me to select the drives.
Isn't it supposed to run unattended? Yes, all of the tools in System Agent are supposed
to run unattended, if the Registry settings are correct. In the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\
Plus!\System Agent\SAGE key, there are subkeys for each of the four tools in
the System Agent.
- Compression Agent
- Disk Defragmenter
- Low disk space notification
- ScanDisk for Windows
Each of the subkeys should have a value called Settings with a binary
value of 01. If the Settings value is set to 00, or if
it is not there, the program will ask the user for input.
Plug and Play is a fantastic feature, and it has saved literally thousands of
hours of fiddling with settings on devices and trying to match them with the software
configuration. One of the downsides, though, is that it never seems to know when
to stop. The next question is a common one that makes administrators crazy.
SOLUTIONS: Even though I installed a printer
driver for my LaserJet 4L, every time I restart my system, I get a message that Windows
95 has found new hardware and is installing the software for it. I already have it,
so why does it keep doing it again? The HP LaserJet 4L and other Plug and Play devices
may have this problem if the Registry is damaged. HKEY_LOCAL_MACHINE\Enum
holds the information about devices configured with Plug and Play. The common keys
to look at are listed in Table 16.1. If Windows 95 tries to keep installing the device,
remove the key, and let Windows 95 reinstall it when you restart the system.
Table 16.1. Common Plug and Play keys.
Key |
Type of Device |
ISAPNP |
ISA devices (sound cards, video cards, and so on) |
LPTENUM |
Parallel devices (printers, ZIP drives, and so on) |
PCI |
PCI devices (video cards, network cards, and so on) |
SCSI |
SCSI host adapters |
SERENUM |
Serial port devices (modems, ports) |
TAPE |
Tape drives |
Yes, it is an old cliché to "just reinstall Windows." Actually, it's
quite rare to need to do that, but it is not uncommon to need to reinstall parts
and pieces. Reinstalling is one of the easy ways to get back to a known state. Be
careful about reinstalling too much, though, because you may create a tremendous
amount of extra work for yourself.
SOLUTIONS: I got an error that said I couldn't
install any more fonts in my system. It says in the Windows 95 Resource Kit that
there is no limit to the number of fonts I can have in Windows 95. What did I do
wrong? Is it the same in NT? You have that many fonts? There is actually a limit
on the number of fonts, based on the maximum size of a key in the Registry. In both
95 and NT, a Registry key cannot be larger than 64KB, not including subkeys. Considering
average filename length, you could get somewhere between 1,000 and 1,500 fonts in
your system before it ran out of space in the Registry. The entry in the Registry
also contains the path if it is different than the Fonts folder. In Figure 16.1,
the Animations font and the Arquitectura Regular font are in a different directory,
as shown by the shortcut arrow.
Figure
16.1. Fonts in the
Fonts folder.
If you need more room, copy any of the fonts that are in another directory into the
Fonts folder, and you will have even more room. Then you can add more fonts.
As soon as some people hear that there are no limits, they have to find
out for sure. On the other hand, that "Oh, I bet I can find the limit!"
mentality is what propels us forward in this technology age.
Sometimes people just want to be left alone, though, as the next question illustrates.
SOLUTIONS: How
can I ensure that no one can come across the network and make changes to my Registry
in Windows NT? You cannot take away all rights to access your Registry without removing
yourself from the network. If you want to limit access to only the members of the
Administrators group, then you need to make your system look like a Server to Registry
editors. By default, NT Server Registries can only be remotely edited by members
of the Administrators group, but NT Workstation can be edited remotely by any user
who is attached to the network, even if she has not logged onto the domain. To restrict
access, add a new key to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet
\Control\SecurePipeServers on your Workstation. The new key is WinReg,
a REG_SZ class entry. In the new key, add a value named Description,
a REG_SZ entry. Edit the Description value, and type in Registry
Server. When you restart the Workstation, everyone but members of the Administrators
group will be restricted from accessing your Registry.
Restricting users from the Registry is particularly important. Imagine the potential
damage if someone tried to edit your Registry and was unfamiliar with the correct
procedures. That's another reason to have a good backup.
SOLUTIONS: I have a ZIP drive that I use with
my notebook that is running NT 4.0. Whenever I do not have it connected, I get error
messages, and errors show up in the event log. How can I make it stop? I know it
is not connected. You can turn off the error reporting in the Registry. Change the
value called ErrorControl in HKEY_LOCAL_MACHINE\SYSTEM\ CurrentControlSet\Services\device
driver. By default, it is set to 1, so if you change it to 0, the
device driver will no longer report errors. Be careful turning off error control,
however, because if something is truly wrong, you won't know that either.
It seems as if every day our computers get slower and slower. (That's actually
good, because we must be getting better.) Here's a question that illustrates the
problem, and a possible solution.
SOLUTIONS: Can I make my NT server faster? Sometimes,
it just feels slow. Hardware is the real key to making your server faster, but you
can set your server priorities to give the most performance to server functions.
Then, all that you do have will be given to the server functions. By default, all
server functions in both Server and Workstation have the same priority in NT 4.0
as foreground applications. To boost the priority so that it is greater than any
foreground application, change the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\
Services\LanmanServer\Parameters key. Add a REG_DWORD value called
ThreadPriority, and set the value to 2. If you set it to 0,
it would run at the priority of background applications. Setting it to 1
is the same as not having a value at all because it would set the priority of server
threads the same as for foreground applications. This Solution won't necessarily
speed up your server, but it will ensure that the server functions are running as
fast as they can.
If you've ever done too much, gone too far, or changed something you shouldn't
have, this next Solution is for you.
SOLUTIONS: I messed up my NT server by changing
a number of variables, and it works worse now than when I started. Help! If you had
a backup of your Registry, you could simply restore that. In the absence of a backup,
you can remove a few values in one key, and Windows NT will reconfigure itself, and
return its parameters. In HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\
Parameters, there are several values. Remove all of them except:
- EnableSharedNetDrives
- LMAnnounce
- NullSessionPipes
- NullSessionShares
- Size
When NT Server is restarted, it will automatically reconfigure its server service
and optimize it with Microsoft's parameters.
Disk space limitations can cause all types of problems. Getting new disk drives
opens up all sorts of new opportunities, or extra performance.
SOLUTIONS: I have a new disk drive, and my C:
drive is getting very full. Can I set it so my printer will spool to another directory
on another drive? Yes, you can, and it only takes a simple Registry entry. Add a
REG_SZ value called DefaultSpoolDirectory to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\
Control\Print\Printers. Set the value to be the name of any current directory
on a local physical drive. If you are going to put the directory on an NTFS partition,
the Everyone group must be given full control. Restart your system, and
when you send a job to print, it will be spooled at the new location.
In many cases, you need to just change the way things work. Someone else makes
software decisions for your organization, and you would like it to work differently.
That is the case with the previous Solution, and the next one, too.
SOLUTIONS: I don't like having a little message
pop up on my screen every time I send something to print to my NT Server. We are
all in the same room. How can I get rid of the annoying messages?You could turn off
the print notification at the server, and then you would only know if the print job
finished by looking at it. HKEY_LOCAL_MACHINE\SYSTEM\
CurrentControlSet\Control\Print\Providers is the key where you need to add a
new DWORD value called NetPopup. Set the NetPopup value
to 0, and the system will no longer bother you with the messages.
The paging file not only makes your systems work better, by allowing you to use
hard disk space as if it were RAM, but it also gives you a safety net for the system.
If your NT system crashes, the paging file can hold the entire contents of RAM for
investigative purposes. You need to make sure the paging file is at least as large
as RAM. Some applications want it extremely large. If your application is particularly
sluggish, consider expanding the size of your paging file.
SOLUTIONS: I got a warning that my maximum Registry
size needed to be expanded. When I went to change it, NT said I needed to expand
my paging file space to do that. Isn't there any other way? Windows NT sets the maximum
Registry size limit by default to 25 percent of the page pool (all of the
paging files added together). If you go past that, you will need to expand the page
pool or expand the percentage for calculating the maximum Registry size. To change
the percentage, add a key named RegistrySizeLimit to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control.
Then add a REG_DWORD value with the same name, RegistrySizeLimit,
to that key. Set the value to the maximum, 0xffffffff, and you should be
OK. It shouldn't bother you again. With the price of hard disk space today, though,
you really ought to consider getting more space and just expanding your paging file
space.
When upgrading from NT 3.51 to 4.0, put in the CD, use the Run command, and, at
the \i386 directory, run WINNT32 /u. That will save all your settings,
users, groups, and replace your current drivers with NT 4.0 drivers. It is fast,
easy, and very efficient.
SOLUTIONS: I want to upgrade to NT 4.0, but I
have HPFS volumes, and the NT documentation says they are not supported in 4.0. Are
there any workarounds to allow me to still use them? If we didn't have one, you can
bet that the question would not be listed here. You will need to copy a file, PINBALL.SYS,
from an NT 3.51 system, and then make some changes to the Registry. Copy PINBALL.SYS
to %systemroot%\System32\Drivers. At the Pinball key, add the values
shown in Table 16.2. These are case-sensitive! When you restart your system, you
will be able to use the HPFS volumes
in NT 4.0.
Table 16.2. Add a value to the Pinball key.
New Values |
Type |
Data |
ErrorControl |
REG_DWORD |
0x1 |
Group |
REG_SZ |
Boot file system |
Start |
REG_DWORD |
0x1 |
Type |
REG_DWORD |
0x2 |
Speaking of pinball, have you tried PINBALL.EXE yet? It is available for
both Windows 95 and for NT 4.0, and brings a new level of gaming to PCs. No more
320x200. This is full-sound, full-motion, high-intensity Super VGA gaming.
Windows NT can run DOS, 16-bit Windows, 32-bit Windows, OS/2, and POSIX applications.
It can also understand most UNIX commands as well. If you run OS/2 applications,
this next Solution may make them work better.
SOLUTIONS: How can I get better performance for
my OS/2 applications in Windows NT? I can't guarantee it, but many applications written
for OS/2 will run faster if you disable the OS/2 subsystem. The applications will
still work, but they will run under a Virtual DOS Machine (VDM). NT gives more resources
to the application in the VDM than it does in the OS/2 subsystem. You won't have
to do anything different to run your applications; you just need to make a simple
Registry change. In HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\ Control\SessionManager,
change the GlobalFlag value from 0 to 20100000. Once you
restart your system, all of your OS/2 applications will use a VDM when they start.
An earlier Solution in this chapter turned off logging. Now you'll learn how to
turn it on for a service that normally doesn't report its errors.
SOLUTIONS: I am having some challenges with RAS
on my NT Server, but there aren't any errors shown in Event Viewer. Can I make it
log the errors there? You can make RAS errors show in the Event Viewer by telling
the system to log them. By default, RAS error logging is turned off. To turn it on,
change the Logging value in HKEY_LOCAL_MACHINE\SYSTEM\ CurrentControlSet\Services\RasMan\Parameters
to 1. After restarting RAS, any errors will automatically be logged to Event
Viewer.
Sometimes it seems that there are annoyances in software that just bug you. Most
of the time, they are the product of a great idea, but sometimes there isn't enough
thought as to how this will feel after the hundredth time it happens. Such is the
case with this next Solution.Solutions
SOLUTIONS: How can I get my system not to automatically
start CD-ROMs when I put them in my system? That really depends on whether you are
running Windows 95 or Windows NT. There is an option in the interface for disabling
the Autorun feature in Windows 95. In NT, you will need to change the Registry. In
Windows 95, to disable both the CD-ROM and audio CD Autorun feature, follow the steps
shown here.
- 1. Go to Control Panel | System | Device Manager | CD-ROM.
2. Open the CD-ROM branch and then go to the properties of the CD-ROM driver.
3. At the Settings tab, clear the Auto Insert Notification box.
When you restart your system, CDs will not automatically play in Windows 95. To
remove the Autorun feature in Windows NT, edit the HKEY_LOCAL_MACHINE\
System\CurrentControlSet\Services\CDRom key. Change the Autorun value
to 0. In either of these instances, it will not affect how your CDs will
run--just when. It does get annoying when you insert a CD-ROM to give the system
a file it needs, and it starts up automatically. It is even more annoying when you
have a CD tower, and when you change one, it will start all of the CDs currently
in the tower.
There is a difference between a CD tower and a CD jukebox. The tower has multiple
drives, each with a CD in it. All of the data is online simultaneously. It works
great as a lookup/database function. A jukebox has many CDs, but only one plays at
a time. If a different CD is needed, the system goes out, finds it, and then plays
it. A tower is a great option for a network, but using a jukebox on a network might
not be the best solution. If multiple users are trying to access different CDs on
the same machine, that machine would spend most of its time switching between the
two.
SOLUTIONS: Windows 95 was installed on my system
with a CD-ROM, so whenever I need to make changes to my system, it always prompts
me for a CD, which I don't have at my desk. All of the files have been copied to
the server, and I want it to automatically go there for the files. Is that possible?
It is not only possible, it may be the best way to do it. A change in the Registry
will change where it looks for your Windows 95 files. You could also do this for
Windows NT, but the Registry change is in a different location. To change the Registry
for Windows 95 systems, edit the HKEY_LOCAL_MACHINE\
Software\Microsoft\Windows\CurrentVersion\Setup key. Change the path in the
SourcePath value to the new location. That location can either be a local
directory, a UNC to a shared directory on the network, or a mapped drive letter.
In Windows NT, the Registry key is HKEY_LOCAL_MACHINE\Software\ Microsoft\Windows
NT\CurrentVersion. The SourcePath value is the same, and the limitations
are the same. That should make it a lot easier to change your system.
Summary
Without a doubt, one of the most important things you can do as administrators
is to optimize the performance of your systems. That has almost as much to do with
keeping them working as it does with smoothing out the rough spots that get in the
way of optimum performance. This chapter demonstrates how to do both.
|